#include "Drawable.h"

Drawable::Drawable() : position(0), orientation(0.0f), model(MODEL_NULL){}

Drawable::Drawable(float x, float y, float orientation,EModel model)
{
	this->position = new Coord(x,y);
	this->orientation = orientation;
	this->model=model;
	if (this->model == MODEL_CAR) {
		this->setSize(4.0,1.5);
	}else if (this->model == MODEL_TRUCK ) {
		this->setSize(6.0,2.0);
	}
}

Drawable::~Drawable(void){}

Coord* Drawable::getPosition() const{
	return this->position;
}

void Drawable::setPosition(Coord* position){
	this->position = position;
}

float Drawable::getOrientation() const{
	 return this->orientation;
}

void Drawable::setOrientation(float orientation){
	this->orientation = orientation;
}

EModel Drawable::getModel() const{
	return this->model;
}

void Drawable::setModel(EModel model){
	this->model = model;
}

void Drawable::setSize(float x,float y){
	this->size = new Coord(x,y);
}
Coord* Drawable::getSize(){
	return this->size;
}